Skip to content

Conversation

hageboeck
Copy link
Member

@hageboeck hageboeck commented Sep 30, 2025

Usually, CMake automatically sets RUNPATH when target_link_libraries is
used. However, since Core doesn't have other ROOT dependencies, its
RUNPATH might only contain external dependencies or remain empty.
To enable Core to find other ROOT libraries, its current location is
added to its BUILD_RPATH.
If this isn't done, dlopen might find ROOT libraries which are installed in system locations.

@hageboeck hageboeck self-assigned this Sep 30, 2025
Copy link

github-actions bot commented Sep 30, 2025

Test Results

    22 files      22 suites   3d 16h 36m 25s ⏱️
 3 688 tests  3 687 ✅ 0 💤 1 ❌
79 202 runs  79 201 ✅ 0 💤 1 ❌

For more details on these failures, see this check.

Results for commit f175cf6.

♻️ This comment has been updated with latest results.

@guitargeek
Copy link
Contributor

I have solved a similar problem in 47caba5 for TROOT, so TROOT::GetLibDir() should give you the right path already. Maybe you can re-use that?

@hageboeck hageboeck force-pushed the loader_issues branch 2 times, most recently from 5c30111 to b31259b Compare October 9, 2025 08:53
@hageboeck hageboeck added the clean build Ask CI to do non-incremental build on PR label Oct 9, 2025
@hageboeck hageboeck marked this pull request as ready for review October 9, 2025 12:56
@hageboeck hageboeck requested a review from bellenot as a code owner October 9, 2025 12:56
@hageboeck
Copy link
Member Author

I have solved a similar problem in 47caba5 for TROOT, so TROOT::GetLibDir() should give you the right path already. Maybe you can re-use that?

@guitargeek I removed the changes to the path searching from this PR. I would need more time to rework this.

@hageboeck hageboeck requested a review from guitargeek October 9, 2025 12:57
Copy link
Contributor

@guitargeek guitargeek left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Great, thanks a lot!

Copy link
Member

@pcanal pcanal left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks.

Usually, CMake automatically sets RUNPATH when target_link_libraries is
used. However, since Core doesn't have other ROOT dependencies, its
RUNPATH might only contain external dependencies or remain empty.
To enable Core to find other ROOT libraries, its current location is
added to its BUILD_RPATH.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

clean build Ask CI to do non-incremental build on PR

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants